
<div class="info">	
	<div class="conteudo-admin">
	<h2>Galeria de Fotos</h2>
	<div class="forms-admin">
<p class="novaCat"><a href="<?PHP echo $this->url(array('action' => 'adicionarGaleria')); ?>">Adicionar galeria</a></p>
    <table border="1" width="100%">
        <tr class="linha3">
            <th>Id</th>
            <th>Galeria</th>
            <th align="center">Editar</th>
            <th align="center">Remover</th>
        </tr>
	<?php $linha = 0;?>
    <?PHP foreach ($this->galerias as $galerias): ?>
        <?php 
			if($linha == 0){
				echo '<tr class="linha1">';
				$linha = 1;
			}else{
				echo '<tr class="linha2">';
				$linha = 0;
			}
			?>
            <td><?PHP echo $galerias['id_galeria']; ?></td>
            <td><?PHP echo $galerias['nome']; ?></td>
            <td align="center"><a href="<?PHP echo $this->url(array('action' => 'editarGaleria', 'id' => $galerias['id_galeria'])); ?>">X</a></td>
            <td align="center"><a href="<?PHP echo $this->url(array('action' => 'removerGaleria', 'id' => $galerias['id_galeria'])); ?>">X</a></td>
        </tr>
    <?PHP endforeach; ?>
    </table>
    

<p class="novaCat"><a href="<?PHP echo $this->url(array('action' => 'adicionar')); ?>">Adicionar nova imagem</a></p>
    <table border="1" width="100%">
        <tr class="linha3">
            <th>Id</th>
            <th>Descrição</th>
            <th>Galeria</th>
            <th align="center">Editar</th>
            <th align="center">Remover</th>
        </tr>
    <?PHP foreach ($this->galeria as $galeria): ?>
        <?php 
			if($linha == 0){
				echo '<tr class="linha1">';
				$linha = 1;
			}else{
				echo '<tr class="linha2">';
				$linha = 0;
			}
			?>
            <td><?PHP echo $galeria['id_foto']; ?></td>
            <td><?PHP echo $galeria['descricao']; ?></td>
            <td><?PHP echo $galeria['galeria']; ?></td>
            <td align="center"><a href="<?PHP echo $this->url(array('action' => 'editar', 'id' => $galeria['id_foto'])); ?>">X</a></td>
            <td align="center"><a href="<?PHP echo $this->url(array('action' => 'remover', 'id' => $galeria['id_foto'])); ?>">X</a></td>
        </tr>
    <?PHP endforeach; ?>
    </table>
	</div>
	</div>
	</div>